{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {},
   "outputs": [],
   "source": [
    "#####utils\n",
    "##########\n",
    "\n",
    "import numpy as np\n",
    "import scipy.sparse as sp\n",
    "import torch\n",
    "\n",
    "\n",
    "def encode_onehot(labels):\n",
    "    classes = set(labels)\n",
    "    classes_dict = {c: np.identity(len(classes))[i, :] for i, c in\n",
    "                    enumerate(classes)}\n",
    "    labels_onehot = np.array(list(map(classes_dict.get, labels)),\n",
    "                             dtype=np.int32)\n",
    "    return labels_onehot\n",
    "\n",
    "\n",
    "\n",
    "\n",
    "def normalize(mx):\n",
    "    \"\"\"Row-normalize sparse matrix\"\"\"\n",
    "    rowsum = np.array(mx.sum(1))\n",
    "    r_inv = np.power(rowsum, -1).flatten()\n",
    "    r_inv[np.isinf(r_inv)] = 0.\n",
    "    r_mat_inv = sp.diags(r_inv)\n",
    "    mx = r_mat_inv.dot(mx)\n",
    "    return mx\n",
    "\n",
    "\n",
    "def accuracy(output, labels):\n",
    "    preds = output.max(1)[1].type_as(labels)\n",
    "    correct = preds.eq(labels).double()\n",
    "    correct = correct.sum()\n",
    "    return correct / len(labels)\n",
    "\n",
    "\n",
    "def sparse_mx_to_torch_sparse_tensor(sparse_mx):\n",
    "    \"\"\"Convert a scipy sparse matrix to a torch sparse tensor.\"\"\"\n",
    "    sparse_mx = sparse_mx.tocoo().astype(np.float32)\n",
    "    indices = torch.from_numpy(\n",
    "        np.vstack((sparse_mx.row, sparse_mx.col)).astype(np.int64))\n",
    "    values = torch.from_numpy(sparse_mx.data)\n",
    "    shape = torch.Size(sparse_mx.shape)\n",
    "    return torch.sparse.FloatTensor(indices, values, shape)\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 36,
   "metadata": {},
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "import scipy.sparse as sp\n",
    "import random\n",
    "def load_data(path=\"/Users/stephenye/Desktop/2019summer/pygcn-master/data/MUTAG/\", dataset=\"MUTAG\"):\n",
    "    \"\"\"Load citation network dataset (cora only for now)\"\"\"\n",
    "    print('Loading {} dataset...'.format(dataset))\n",
    "\n",
    "    N = 188 ## num of graphs\n",
    "    y = np.genfromtxt(\"{}{}_graph_labels.txt\".format(path, dataset),dtype=np.dtype(int))\n",
    "    idx_features = np.genfromtxt(\"{}{}_node_labels.txt\".format(path, dataset),dtype=np.dtype(float))\n",
    "    idx_indicator = np.genfromtxt(\"{}{}_graph_indicator.txt\".format(path, dataset),dtype=np.dtype(int))\n",
    "    Adj_M = np.genfromtxt(\"{}{}_A.txt\".format(path, dataset),dtype=np.dtype(float),delimiter=\",\")\n",
    "    \n",
    "    for i in range(len(y)):\n",
    "        if(y[i]==-1):\n",
    "            y[i]= 0\n",
    "    \n",
    "    n = len(idx_features) ##num of nodes\n",
    "    #create graph dictionary\n",
    "    graph_node_dict = {}\n",
    "    g_idx =0\n",
    "    for i in range(len(idx_indicator)):\n",
    "        if(g_idx != idx_indicator[i]):\n",
    "            graph_node_dict[g_idx+1] = i\n",
    "            g_idx +=1\n",
    "    graph_node_dict[189] = len(idx_indicator)\n",
    "    \n",
    "    #build graphs\n",
    "    A = np.zeros((n,n))\n",
    "    for i in range(len(Adj_M)):\n",
    "        A[int(Adj_M[i][0]-1)][int(Adj_M[i][1]-1)] = 1\n",
    "        \n",
    "\n",
    "    A = A + np.matmul(A.T,(A.T > A)) - np.matmul(A,(A.T > A))\n",
    "    full = np.full((3371, 3371), 1)\n",
    "    A = normalize(A + np.diag(np.diag(full)))\n",
    "    \n",
    "    idx_train = torch.tensor(range(110,188))\n",
    "    idx_test = torch.tensor(range(30,110))\n",
    "    idx_val = torch.tensor(range(30))\n",
    "    \n",
    "    A = torch.FloatTensor(A)\n",
    "    y = torch.tensor(y)\n",
    "    idx_features = encode_onehot(idx_features)\n",
    "    idx_features = torch.FloatTensor(idx_features)\n",
    "    return A,graph_node_dict,idx_features,y,idx_train,idx_test,idx_val\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 37,
   "metadata": {},
   "outputs": [],
   "source": [
    "#####layers\n",
    "###########\n",
    "\n",
    "\n",
    "import math\n",
    "\n",
    "import torch\n",
    "\n",
    "from torch.nn.parameter import Parameter\n",
    "from torch.nn.modules.module import Module\n",
    "\n",
    "\n",
    "class GraphConvolution(Module):\n",
    "    \"\"\"\n",
    "    Simple GCN layer, similar to https://arxiv.org/abs/1609.02907\n",
    "    \"\"\"\n",
    "\n",
    "    def __init__(self, in_features, out_features, bias=True):\n",
    "        super(GraphConvolution, self).__init__()\n",
    "        self.in_features = in_features\n",
    "        self.out_features = out_features\n",
    "        self.weight = Parameter(torch.FloatTensor(in_features, out_features))\n",
    "        if bias:\n",
    "            self.bias = Parameter(torch.FloatTensor(out_features))\n",
    "        else:\n",
    "            self.register_parameter('bias', None)\n",
    "        self.reset_parameters()\n",
    "\n",
    "    def reset_parameters(self):\n",
    "        stdv = 1. / math.sqrt(self.weight.size(1))\n",
    "        self.weight.data.uniform_(-stdv, stdv)\n",
    "        if self.bias is not None:\n",
    "            self.bias.data.uniform_(-stdv, stdv)\n",
    "\n",
    "    def forward(self, input, adj):\n",
    "        #self.weight = self.weight.long()\n",
    "        support = torch.matmul(input, self.weight)\n",
    "        output = torch.matmul(adj, support)\n",
    "        if self.bias is not None:\n",
    "            return output + self.bias\n",
    "        else:\n",
    "            return output\n",
    "\n",
    "    def __repr__(self):\n",
    "        return self.__class__.__name__ + ' (' \\\n",
    "               + str(self.in_features) + ' -> ' \\\n",
    "               + str(self.out_features) + ')'\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 38,
   "metadata": {},
   "outputs": [],
   "source": [
    "#####GCN\n",
    "########\n",
    "import torch.nn as nn\n",
    "import torch.nn.functional as F\n",
    "##from pygcn.layers import GraphConvolution\n",
    "\n",
    "\n",
    "class GCN(nn.Module):\n",
    "    def __init__(self, nfeat, nhid, nclass, dropout):\n",
    "        super(GCN, self).__init__()\n",
    "\n",
    "        self.gc1 = GraphConvolution(nfeat, nhid)\n",
    "        self.gc2 = GraphConvolution(nhid, nclass)\n",
    "        self.dropout = dropout\n",
    "\n",
    "    def forward(self, x, adj,diction):\n",
    "        \n",
    "        x = F.relu(self.gc1(x, adj))\n",
    "        \n",
    "        x = F.dropout(x, self.dropout, training=self.training)\n",
    "        x = self.gc2(x, adj)\n",
    "        x = F.log_softmax(x, dim=1)\n",
    "        \n",
    "        new_x = torch.tensor(np.zeros((188,2)))\n",
    "        \n",
    "        for i in range(188):  ##this may cause bug\n",
    "            start = int(diction[i+1])\n",
    "            end = int(diction[i+2])\n",
    "            new_x[i] = torch.mean(x[start:end],0)\n",
    "        output = new_x\n",
    "        \n",
    "        return new_x\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 39,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Loading MUTAG dataset...\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "tensor([[0.3333, 0.3333, 0.0000,  ..., 0.0000, 0.0000, 0.0000],\n",
       "        [0.3333, 0.3333, 0.3333,  ..., 0.0000, 0.0000, 0.0000],\n",
       "        [0.0000, 0.3333, 0.3333,  ..., 0.0000, 0.0000, 0.0000],\n",
       "        ...,\n",
       "        [0.0000, 0.0000, 0.0000,  ..., 0.2500, 0.2500, 0.2500],\n",
       "        [0.0000, 0.0000, 0.0000,  ..., 0.5000, 0.5000, 0.0000],\n",
       "        [0.0000, 0.0000, 0.0000,  ..., 0.5000, 0.0000, 0.5000]])"
      ]
     },
     "execution_count": 39,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "from __future__ import division\n",
    "from __future__ import print_function\n",
    "\n",
    "import time\n",
    "import argparse\n",
    "import numpy as np\n",
    "\n",
    "import torch\n",
    "import torch.nn.functional as F\n",
    "import torch.optim as optim\n",
    "\n",
    "\n",
    "n_seed = 42\n",
    "n_epochs = 200\n",
    "_lr = 0.01\n",
    "_weight_decay = 5e-4\n",
    "n_hidden = 16\n",
    "_dropout = 0.5\n",
    "# Training settings\n",
    "#parser = argparse.ArgumentParser()\n",
    "#parser.add_argument('--no-cuda', action='store_true', default=False,\n",
    "                    #help='Disables CUDA training.')\n",
    "#parser.add_argument('--fastmode', action='store_true', default=False,\n",
    "                    #help='Validate during training pass.')\n",
    "#parser.add_argument('--seed', type=int, default=42, help='Random seed.')\n",
    "#parser.add_argument('--epochs', type=int, default=200,\n",
    "                    #help='Number of epochs to train.')\n",
    "#parser.add_argument('--lr', type=float, default=0.01,\n",
    "                    #help='Initial learning rate.')\n",
    "#parser.add_argument('--weight_decay', type=float, default=5e-4,\n",
    "                    #help='Weight decay (L2 loss on parameters).')\n",
    "#parser.add_argument('--hidden', type=int, default=16,\n",
    "                    #help='Number of hidden units.')\n",
    "#parser.add_argument('--dropout', type=float, default=0.5,\n",
    "                    #help='Dropout rate (1 - keep probability).')\n",
    "\n",
    "#args = parser.parse_args()\n",
    "#args.cuda = not args.no_cuda and torch.cuda.is_available()\n",
    "\n",
    "np.random.seed(n_seed)\n",
    "torch.manual_seed(n_seed)\n",
    "\n",
    "\n",
    "# Load data\n",
    "adj,g_dict,features,labels,idx_train, idx_test,idx_val = load_data()\n",
    "torch.mean(features[3:5],0)\n",
    "features[3:5]\n",
    "adj"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 40,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0001 loss_train: 0.8462 acc_train: 0.4359 loss_val: 0.9727 acc_val: 0.2667 time: 0.0820s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0002 loss_train: 0.8203 acc_train: 0.4359 loss_val: 0.9445 acc_val: 0.2667 time: 0.0625s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0003 loss_train: 0.8049 acc_train: 0.4359 loss_val: 0.9094 acc_val: 0.2667 time: 0.0599s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0004 loss_train: 0.7823 acc_train: 0.4359 loss_val: 0.8802 acc_val: 0.2667 time: 0.0712s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0005 loss_train: 0.7670 acc_train: 0.4359 loss_val: 0.8602 acc_val: 0.2667 time: 0.0668s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0006 loss_train: 0.7540 acc_train: 0.4359 loss_val: 0.8390 acc_val: 0.2667 time: 0.0639s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0007 loss_train: 0.7448 acc_train: 0.4359 loss_val: 0.8140 acc_val: 0.2667 time: 0.0607s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0008 loss_train: 0.7293 acc_train: 0.4359 loss_val: 0.7901 acc_val: 0.2667 time: 0.0703s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0009 loss_train: 0.7247 acc_train: 0.4359 loss_val: 0.7653 acc_val: 0.2667 time: 0.0605s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0010 loss_train: 0.7139 acc_train: 0.4359 loss_val: 0.7469 acc_val: 0.2667 time: 0.0622s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0011 loss_train: 0.7054 acc_train: 0.4359 loss_val: 0.7366 acc_val: 0.2667 time: 0.0712s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0012 loss_train: 0.7030 acc_train: 0.4359 loss_val: 0.7225 acc_val: 0.2667 time: 0.0634s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0013 loss_train: 0.7011 acc_train: 0.4359 loss_val: 0.7090 acc_val: 0.3667 time: 0.0587s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0014 loss_train: 0.6897 acc_train: 0.5385 loss_val: 0.7034 acc_val: 0.3333 time: 0.0614s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0015 loss_train: 0.6930 acc_train: 0.5769 loss_val: 0.6991 acc_val: 0.5667 time: 0.0683s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0016 loss_train: 0.6850 acc_train: 0.6026 loss_val: 0.6796 acc_val: 0.6333 time: 0.0622s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0017 loss_train: 0.6812 acc_train: 0.6410 loss_val: 0.6763 acc_val: 0.7000 time: 0.0576s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0018 loss_train: 0.6869 acc_train: 0.5769 loss_val: 0.6653 acc_val: 0.7333 time: 0.0728s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0019 loss_train: 0.6812 acc_train: 0.5897 loss_val: 0.6513 acc_val: 0.7333 time: 0.0736s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0020 loss_train: 0.6840 acc_train: 0.5897 loss_val: 0.6516 acc_val: 0.7333 time: 0.0760s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0021 loss_train: 0.6754 acc_train: 0.5641 loss_val: 0.6414 acc_val: 0.7333 time: 0.0841s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0022 loss_train: 0.6900 acc_train: 0.5641 loss_val: 0.6480 acc_val: 0.7333 time: 0.0736s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0023 loss_train: 0.6764 acc_train: 0.5769 loss_val: 0.6301 acc_val: 0.7333 time: 0.0728s\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0024 loss_train: 0.6786 acc_train: 0.5641 loss_val: 0.6264 acc_val: 0.7333 time: 0.1709s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0025 loss_train: 0.6823 acc_train: 0.5641 loss_val: 0.6141 acc_val: 0.7333 time: 0.1866s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0026 loss_train: 0.6850 acc_train: 0.5641 loss_val: 0.6149 acc_val: 0.7333 time: 0.1325s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0027 loss_train: 0.6734 acc_train: 0.5641 loss_val: 0.6255 acc_val: 0.7333 time: 0.1442s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0028 loss_train: 0.6708 acc_train: 0.5641 loss_val: 0.6188 acc_val: 0.7333 time: 0.1232s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0029 loss_train: 0.6858 acc_train: 0.5641 loss_val: 0.6257 acc_val: 0.7333 time: 0.1077s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0030 loss_train: 0.6714 acc_train: 0.5641 loss_val: 0.6177 acc_val: 0.7333 time: 0.0756s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0031 loss_train: 0.6721 acc_train: 0.5641 loss_val: 0.6261 acc_val: 0.7333 time: 0.0730s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0032 loss_train: 0.6607 acc_train: 0.5897 loss_val: 0.6270 acc_val: 0.7333 time: 0.0842s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0033 loss_train: 0.6793 acc_train: 0.5769 loss_val: 0.6314 acc_val: 0.7333 time: 0.0742s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0034 loss_train: 0.6717 acc_train: 0.5897 loss_val: 0.6242 acc_val: 0.7333 time: 0.0704s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0035 loss_train: 0.6704 acc_train: 0.6026 loss_val: 0.6153 acc_val: 0.7333 time: 0.0876s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0036 loss_train: 0.6717 acc_train: 0.6154 loss_val: 0.6169 acc_val: 0.7333 time: 0.0845s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0037 loss_train: 0.6741 acc_train: 0.6154 loss_val: 0.6268 acc_val: 0.7333 time: 0.0750s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0038 loss_train: 0.6833 acc_train: 0.6026 loss_val: 0.6266 acc_val: 0.7333 time: 0.0771s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0039 loss_train: 0.6635 acc_train: 0.6282 loss_val: 0.6429 acc_val: 0.7333 time: 0.0634s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0040 loss_train: 0.6626 acc_train: 0.6410 loss_val: 0.6285 acc_val: 0.7000 time: 0.0613s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0041 loss_train: 0.6686 acc_train: 0.6026 loss_val: 0.6250 acc_val: 0.7333 time: 0.0635s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0042 loss_train: 0.6671 acc_train: 0.6154 loss_val: 0.6103 acc_val: 0.7667 time: 0.0817s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0043 loss_train: 0.6720 acc_train: 0.6154 loss_val: 0.6173 acc_val: 0.7333 time: 0.1854s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0044 loss_train: 0.6654 acc_train: 0.5897 loss_val: 0.6195 acc_val: 0.7333 time: 0.1051s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0045 loss_train: 0.6570 acc_train: 0.6026 loss_val: 0.6184 acc_val: 0.7667 time: 0.0659s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0046 loss_train: 0.6624 acc_train: 0.6026 loss_val: 0.6148 acc_val: 0.7000 time: 0.0730s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0047 loss_train: 0.6497 acc_train: 0.6923 loss_val: 0.6238 acc_val: 0.7333 time: 0.0604s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0048 loss_train: 0.6478 acc_train: 0.6538 loss_val: 0.6183 acc_val: 0.7667 time: 0.0620s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 0049 loss_train: 0.6552 acc_train: 0.6667 loss_val: 0.6181 acc_val: 0.7000 time: 0.0746s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0050 loss_train: 0.6466 acc_train: 0.6538 loss_val: 0.6202 acc_val: 0.7667 time: 0.0911s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0051 loss_train: 0.6546 acc_train: 0.6667 loss_val: 0.6159 acc_val: 0.7333 time: 0.1495s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0052 loss_train: 0.6467 acc_train: 0.6538 loss_val: 0.6126 acc_val: 0.7000 time: 0.0954s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0053 loss_train: 0.6544 acc_train: 0.6795 loss_val: 0.6022 acc_val: 0.7333 time: 0.0670s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0054 loss_train: 0.6481 acc_train: 0.6923 loss_val: 0.6038 acc_val: 0.7667 time: 0.0706s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0055 loss_train: 0.6399 acc_train: 0.7051 loss_val: 0.6042 acc_val: 0.7667 time: 0.0620s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0056 loss_train: 0.6401 acc_train: 0.6923 loss_val: 0.6027 acc_val: 0.7333 time: 0.0619s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0057 loss_train: 0.6391 acc_train: 0.6923 loss_val: 0.5991 acc_val: 0.7333 time: 0.1283s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0058 loss_train: 0.6460 acc_train: 0.6667 loss_val: 0.5979 acc_val: 0.7333 time: 0.1216s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0059 loss_train: 0.6443 acc_train: 0.6667 loss_val: 0.5928 acc_val: 0.7333 time: 0.1243s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0060 loss_train: 0.6338 acc_train: 0.6923 loss_val: 0.5831 acc_val: 0.7333 time: 0.1083s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0061 loss_train: 0.6331 acc_train: 0.6667 loss_val: 0.6038 acc_val: 0.7333 time: 0.1233s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0062 loss_train: 0.6311 acc_train: 0.7179 loss_val: 0.5980 acc_val: 0.7333 time: 0.1423s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0063 loss_train: 0.6321 acc_train: 0.7051 loss_val: 0.5958 acc_val: 0.7667 time: 0.1013s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0064 loss_train: 0.6361 acc_train: 0.6923 loss_val: 0.6056 acc_val: 0.7333 time: 0.1003s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0065 loss_train: 0.6311 acc_train: 0.7051 loss_val: 0.5994 acc_val: 0.7333 time: 0.0927s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0066 loss_train: 0.6316 acc_train: 0.6923 loss_val: 0.5878 acc_val: 0.7333 time: 0.0864s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0067 loss_train: 0.6307 acc_train: 0.7051 loss_val: 0.5863 acc_val: 0.7333 time: 0.0624s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0068 loss_train: 0.6402 acc_train: 0.7051 loss_val: 0.5814 acc_val: 0.7333 time: 0.0628s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0069 loss_train: 0.6282 acc_train: 0.6923 loss_val: 0.6041 acc_val: 0.7667 time: 0.0760s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0070 loss_train: 0.6268 acc_train: 0.6667 loss_val: 0.5872 acc_val: 0.7333 time: 0.0739s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0071 loss_train: 0.6208 acc_train: 0.7051 loss_val: 0.5921 acc_val: 0.7667 time: 0.0771s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 0072 loss_train: 0.6267 acc_train: 0.6795 loss_val: 0.5944 acc_val: 0.7333 time: 0.1081s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0073 loss_train: 0.6262 acc_train: 0.6795 loss_val: 0.5821 acc_val: 0.7333 time: 0.1514s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0074 loss_train: 0.6273 acc_train: 0.6923 loss_val: 0.5994 acc_val: 0.7333 time: 0.1960s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0075 loss_train: 0.6252 acc_train: 0.7051 loss_val: 0.6043 acc_val: 0.7333 time: 0.0667s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0076 loss_train: 0.6110 acc_train: 0.7436 loss_val: 0.5865 acc_val: 0.7333 time: 0.0716s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0077 loss_train: 0.6135 acc_train: 0.7179 loss_val: 0.5974 acc_val: 0.7667 time: 0.0732s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0078 loss_train: 0.6257 acc_train: 0.6923 loss_val: 0.5981 acc_val: 0.7333 time: 0.0721s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0079 loss_train: 0.6226 acc_train: 0.6923 loss_val: 0.5959 acc_val: 0.7333 time: 0.0853s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0080 loss_train: 0.6150 acc_train: 0.7436 loss_val: 0.5800 acc_val: 0.7667 time: 0.0683s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0081 loss_train: 0.6208 acc_train: 0.7179 loss_val: 0.5695 acc_val: 0.7333 time: 0.0621s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0082 loss_train: 0.6242 acc_train: 0.6923 loss_val: 0.5769 acc_val: 0.7333 time: 0.0712s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0083 loss_train: 0.6193 acc_train: 0.7051 loss_val: 0.5805 acc_val: 0.7333 time: 0.0881s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0084 loss_train: 0.6237 acc_train: 0.7051 loss_val: 0.5847 acc_val: 0.7333 time: 0.0858s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0085 loss_train: 0.6219 acc_train: 0.6923 loss_val: 0.6050 acc_val: 0.7667 time: 0.0735s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0086 loss_train: 0.6212 acc_train: 0.7308 loss_val: 0.5759 acc_val: 0.7667 time: 0.0639s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0087 loss_train: 0.6100 acc_train: 0.7564 loss_val: 0.5772 acc_val: 0.7667 time: 0.0658s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0088 loss_train: 0.6256 acc_train: 0.7051 loss_val: 0.5917 acc_val: 0.7333 time: 0.0728s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0089 loss_train: 0.6188 acc_train: 0.7436 loss_val: 0.5722 acc_val: 0.7333 time: 0.0661s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0090 loss_train: 0.6119 acc_train: 0.7179 loss_val: 0.5729 acc_val: 0.7333 time: 0.0635s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0091 loss_train: 0.6105 acc_train: 0.6923 loss_val: 0.5784 acc_val: 0.7333 time: 0.0670s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0092 loss_train: 0.6100 acc_train: 0.7051 loss_val: 0.5705 acc_val: 0.7333 time: 0.1743s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0093 loss_train: 0.6086 acc_train: 0.7051 loss_val: 0.5835 acc_val: 0.7333 time: 0.1208s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0094 loss_train: 0.6054 acc_train: 0.7308 loss_val: 0.5899 acc_val: 0.7333 time: 0.1005s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 0095 loss_train: 0.6018 acc_train: 0.7051 loss_val: 0.5867 acc_val: 0.7333 time: 0.1115s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0096 loss_train: 0.6027 acc_train: 0.7051 loss_val: 0.5684 acc_val: 0.7333 time: 0.1154s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0097 loss_train: 0.6126 acc_train: 0.7564 loss_val: 0.5839 acc_val: 0.7667 time: 0.1123s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0098 loss_train: 0.6118 acc_train: 0.7308 loss_val: 0.5974 acc_val: 0.7333 time: 0.1112s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0099 loss_train: 0.6158 acc_train: 0.7436 loss_val: 0.5727 acc_val: 0.7667 time: 0.1385s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0100 loss_train: 0.6104 acc_train: 0.7051 loss_val: 0.5713 acc_val: 0.7333 time: 0.1144s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0101 loss_train: 0.6113 acc_train: 0.7179 loss_val: 0.5861 acc_val: 0.7333 time: 0.0668s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0102 loss_train: 0.6035 acc_train: 0.7564 loss_val: 0.5904 acc_val: 0.7333 time: 0.0681s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0103 loss_train: 0.6146 acc_train: 0.7179 loss_val: 0.5756 acc_val: 0.7667 time: 0.0638s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0104 loss_train: 0.6077 acc_train: 0.7692 loss_val: 0.5975 acc_val: 0.7667 time: 0.0600s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0105 loss_train: 0.6097 acc_train: 0.7308 loss_val: 0.5740 acc_val: 0.7333 time: 0.0681s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0106 loss_train: 0.6118 acc_train: 0.6795 loss_val: 0.5658 acc_val: 0.7667 time: 0.0637s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0107 loss_train: 0.6083 acc_train: 0.7179 loss_val: 0.5860 acc_val: 0.7667 time: 0.0640s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0108 loss_train: 0.6161 acc_train: 0.7308 loss_val: 0.5743 acc_val: 0.8000 time: 0.0773s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0109 loss_train: 0.6125 acc_train: 0.7179 loss_val: 0.5881 acc_val: 0.7667 time: 0.1433s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0110 loss_train: 0.6033 acc_train: 0.7308 loss_val: 0.5780 acc_val: 0.7667 time: 0.1178s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0111 loss_train: 0.6100 acc_train: 0.7179 loss_val: 0.5863 acc_val: 0.7333 time: 0.0826s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0112 loss_train: 0.6053 acc_train: 0.7179 loss_val: 0.5859 acc_val: 0.8000 time: 0.0657s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0113 loss_train: 0.6038 acc_train: 0.7179 loss_val: 0.5601 acc_val: 0.7000 time: 0.0678s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0114 loss_train: 0.6102 acc_train: 0.7436 loss_val: 0.5924 acc_val: 0.7667 time: 0.0647s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0115 loss_train: 0.6156 acc_train: 0.7564 loss_val: 0.6001 acc_val: 0.7333 time: 0.0589s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0116 loss_train: 0.6017 acc_train: 0.7821 loss_val: 0.5968 acc_val: 0.7333 time: 0.0594s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0117 loss_train: 0.6053 acc_train: 0.7564 loss_val: 0.5765 acc_val: 0.7667 time: 0.0660s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0118 loss_train: 0.6033 acc_train: 0.7308 loss_val: 0.5787 acc_val: 0.8000 time: 0.1291s\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0119 loss_train: 0.6174 acc_train: 0.7436 loss_val: 0.5878 acc_val: 0.7333 time: 0.1127s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0120 loss_train: 0.6005 acc_train: 0.7179 loss_val: 0.5817 acc_val: 0.8000 time: 0.0907s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0121 loss_train: 0.6078 acc_train: 0.7564 loss_val: 0.5734 acc_val: 0.7667 time: 0.0722s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0122 loss_train: 0.6165 acc_train: 0.7179 loss_val: 0.5794 acc_val: 0.8333 time: 0.0669s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0123 loss_train: 0.6023 acc_train: 0.7692 loss_val: 0.5946 acc_val: 0.8000 time: 0.0628s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0124 loss_train: 0.6115 acc_train: 0.7179 loss_val: 0.5720 acc_val: 0.7667 time: 0.0632s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0125 loss_train: 0.6041 acc_train: 0.7436 loss_val: 0.5752 acc_val: 0.8333 time: 0.1363s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0126 loss_train: 0.6040 acc_train: 0.7436 loss_val: 0.5744 acc_val: 0.7667 time: 0.1319s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0127 loss_train: 0.6057 acc_train: 0.7179 loss_val: 0.5769 acc_val: 0.8000 time: 0.0895s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0128 loss_train: 0.6088 acc_train: 0.6923 loss_val: 0.5866 acc_val: 0.8000 time: 0.0621s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0129 loss_train: 0.5972 acc_train: 0.7308 loss_val: 0.5794 acc_val: 0.8000 time: 0.0649s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0130 loss_train: 0.6050 acc_train: 0.7436 loss_val: 0.5681 acc_val: 0.7667 time: 0.0661s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0131 loss_train: 0.5952 acc_train: 0.7564 loss_val: 0.5827 acc_val: 0.8000 time: 0.0637s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0132 loss_train: 0.6109 acc_train: 0.7179 loss_val: 0.5721 acc_val: 0.8000 time: 0.1136s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0133 loss_train: 0.6039 acc_train: 0.6923 loss_val: 0.5801 acc_val: 0.7333 time: 0.1242s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0134 loss_train: 0.6033 acc_train: 0.7564 loss_val: 0.5881 acc_val: 0.8000 time: 0.1053s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0135 loss_train: 0.5983 acc_train: 0.7308 loss_val: 0.5846 acc_val: 0.7667 time: 0.0859s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0136 loss_train: 0.6136 acc_train: 0.7179 loss_val: 0.5909 acc_val: 0.7667 time: 0.0654s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0137 loss_train: 0.6060 acc_train: 0.7308 loss_val: 0.5881 acc_val: 0.7667 time: 0.0667s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0138 loss_train: 0.6112 acc_train: 0.7179 loss_val: 0.5825 acc_val: 0.8000 time: 0.0646s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0139 loss_train: 0.6090 acc_train: 0.7436 loss_val: 0.5747 acc_val: 0.8000 time: 0.0611s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0140 loss_train: 0.5954 acc_train: 0.7051 loss_val: 0.5771 acc_val: 0.8000 time: 0.0695s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0141 loss_train: 0.5984 acc_train: 0.7179 loss_val: 0.5685 acc_val: 0.8000 time: 0.1527s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 0142 loss_train: 0.6038 acc_train: 0.7308 loss_val: 0.5700 acc_val: 0.7667 time: 0.1001s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0143 loss_train: 0.6054 acc_train: 0.7308 loss_val: 0.5825 acc_val: 0.7333 time: 0.0813s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0144 loss_train: 0.5952 acc_train: 0.7564 loss_val: 0.5817 acc_val: 0.8000 time: 0.0667s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0145 loss_train: 0.6080 acc_train: 0.7051 loss_val: 0.5689 acc_val: 0.8000 time: 0.0695s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0146 loss_train: 0.5912 acc_train: 0.7564 loss_val: 0.5838 acc_val: 0.7667 time: 0.0624s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0147 loss_train: 0.6088 acc_train: 0.6923 loss_val: 0.6055 acc_val: 0.7333 time: 0.0627s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0148 loss_train: 0.6009 acc_train: 0.7564 loss_val: 0.5851 acc_val: 0.7667 time: 0.0640s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0149 loss_train: 0.6108 acc_train: 0.7179 loss_val: 0.5836 acc_val: 0.8000 time: 0.1318s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0150 loss_train: 0.5990 acc_train: 0.7564 loss_val: 0.5704 acc_val: 0.7667 time: 0.1154s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0151 loss_train: 0.5970 acc_train: 0.7821 loss_val: 0.5867 acc_val: 0.7333 time: 0.0988s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0152 loss_train: 0.5959 acc_train: 0.7692 loss_val: 0.5797 acc_val: 0.8333 time: 0.0689s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0153 loss_train: 0.6005 acc_train: 0.7308 loss_val: 0.5842 acc_val: 0.8333 time: 0.0625s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0154 loss_train: 0.5974 acc_train: 0.7564 loss_val: 0.5978 acc_val: 0.8000 time: 0.0688s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0155 loss_train: 0.5962 acc_train: 0.7436 loss_val: 0.5730 acc_val: 0.7333 time: 0.0636s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0156 loss_train: 0.6054 acc_train: 0.7692 loss_val: 0.5913 acc_val: 0.7667 time: 0.0645s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0157 loss_train: 0.6102 acc_train: 0.7051 loss_val: 0.5776 acc_val: 0.7667 time: 0.1587s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0158 loss_train: 0.6114 acc_train: 0.7564 loss_val: 0.5850 acc_val: 0.7667 time: 0.1141s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0159 loss_train: 0.5974 acc_train: 0.7821 loss_val: 0.6010 acc_val: 0.7667 time: 0.0700s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0160 loss_train: 0.6044 acc_train: 0.7436 loss_val: 0.5734 acc_val: 0.8000 time: 0.0618s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0161 loss_train: 0.6029 acc_train: 0.7564 loss_val: 0.6001 acc_val: 0.7333 time: 0.0616s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0162 loss_train: 0.6000 acc_train: 0.7436 loss_val: 0.5919 acc_val: 0.7667 time: 0.0692s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0163 loss_train: 0.6168 acc_train: 0.7179 loss_val: 0.6202 acc_val: 0.7333 time: 0.0629s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0164 loss_train: 0.6064 acc_train: 0.7564 loss_val: 0.5790 acc_val: 0.7667 time: 0.0693s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0165 loss_train: 0.6036 acc_train: 0.7692 loss_val: 0.6035 acc_val: 0.8000 time: 0.1327s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0166 loss_train: 0.6068 acc_train: 0.7564 loss_val: 0.5935 acc_val: 0.8000 time: 0.1095s\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0167 loss_train: 0.6011 acc_train: 0.7564 loss_val: 0.6087 acc_val: 0.7667 time: 0.0774s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0168 loss_train: 0.6019 acc_train: 0.7821 loss_val: 0.5924 acc_val: 0.7667 time: 0.0651s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0169 loss_train: 0.6052 acc_train: 0.7564 loss_val: 0.5866 acc_val: 0.8333 time: 0.0603s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0170 loss_train: 0.5975 acc_train: 0.7564 loss_val: 0.5825 acc_val: 0.8000 time: 0.0674s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0171 loss_train: 0.6036 acc_train: 0.7564 loss_val: 0.5907 acc_val: 0.7667 time: 0.0667s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0172 loss_train: 0.6127 acc_train: 0.7179 loss_val: 0.6013 acc_val: 0.7667 time: 0.1314s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0173 loss_train: 0.6068 acc_train: 0.7179 loss_val: 0.5823 acc_val: 0.8000 time: 0.1189s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0174 loss_train: 0.6149 acc_train: 0.7308 loss_val: 0.5914 acc_val: 0.7333 time: 0.0875s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0175 loss_train: 0.6058 acc_train: 0.7564 loss_val: 0.6067 acc_val: 0.7667 time: 0.0705s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0176 loss_train: 0.6025 acc_train: 0.7308 loss_val: 0.5924 acc_val: 0.7667 time: 0.0633s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0177 loss_train: 0.5987 acc_train: 0.7564 loss_val: 0.6161 acc_val: 0.7333 time: 0.0622s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0178 loss_train: 0.5976 acc_train: 0.7436 loss_val: 0.5983 acc_val: 0.7333 time: 0.0632s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0179 loss_train: 0.5931 acc_train: 0.7564 loss_val: 0.5939 acc_val: 0.7667 time: 0.1378s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0180 loss_train: 0.6033 acc_train: 0.7308 loss_val: 0.6064 acc_val: 0.8000 time: 0.1180s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0181 loss_train: 0.5997 acc_train: 0.7308 loss_val: 0.6056 acc_val: 0.7333 time: 0.0764s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0182 loss_train: 0.5984 acc_train: 0.7564 loss_val: 0.6224 acc_val: 0.7333 time: 0.0638s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0183 loss_train: 0.5971 acc_train: 0.8077 loss_val: 0.6144 acc_val: 0.8000 time: 0.0604s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0184 loss_train: 0.6030 acc_train: 0.7821 loss_val: 0.5904 acc_val: 0.7667 time: 0.0669s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0185 loss_train: 0.5983 acc_train: 0.7436 loss_val: 0.5909 acc_val: 0.7333 time: 0.1309s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0186 loss_train: 0.6082 acc_train: 0.7564 loss_val: 0.5785 acc_val: 0.8000 time: 0.1224s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0187 loss_train: 0.5983 acc_train: 0.7692 loss_val: 0.5739 acc_val: 0.7667 time: 0.0975s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0188 loss_train: 0.5869 acc_train: 0.7692 loss_val: 0.5773 acc_val: 0.8333 time: 0.0675s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 0189 loss_train: 0.6012 acc_train: 0.7436 loss_val: 0.5893 acc_val: 0.7667 time: 0.0696s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0190 loss_train: 0.6022 acc_train: 0.7564 loss_val: 0.5708 acc_val: 0.7667 time: 0.0647s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0191 loss_train: 0.6056 acc_train: 0.7436 loss_val: 0.6015 acc_val: 0.7667 time: 0.0619s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0192 loss_train: 0.5952 acc_train: 0.7308 loss_val: 0.5930 acc_val: 0.7667 time: 0.0642s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0193 loss_train: 0.5988 acc_train: 0.7179 loss_val: 0.5876 acc_val: 0.7667 time: 0.1541s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0194 loss_train: 0.6044 acc_train: 0.7692 loss_val: 0.5664 acc_val: 0.7333 time: 0.1027s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0195 loss_train: 0.6078 acc_train: 0.7308 loss_val: 0.6078 acc_val: 0.8000 time: 0.0826s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0196 loss_train: 0.6095 acc_train: 0.7051 loss_val: 0.5914 acc_val: 0.7333 time: 0.0661s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0197 loss_train: 0.6061 acc_train: 0.7308 loss_val: 0.5797 acc_val: 0.7667 time: 0.0638s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0198 loss_train: 0.6008 acc_train: 0.7564 loss_val: 0.5773 acc_val: 0.7333 time: 0.0697s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0199 loss_train: 0.6105 acc_train: 0.7179 loss_val: 0.5780 acc_val: 0.7667 time: 0.0652s\n",
      "tensor([0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
      "        0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1,\n",
      "        1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0,\n",
      "        1, 1, 0, 0, 1, 0])\n",
      "Epoch: 0200 loss_train: 0.5961 acc_train: 0.7436 loss_val: 0.6046 acc_val: 0.7000 time: 0.1136s\n",
      "Optimization Finished!\n",
      "Total time elapsed: 17.4192s\n",
      "Test set results: loss= 0.6342 accuracy= 0.7375\n"
     ]
    }
   ],
   "source": [
    "# Model and optimizer\n",
    "model = GCN(nfeat=7,\n",
    "            nhid=n_hidden,\n",
    "            nclass=2,\n",
    "            dropout=_dropout)\n",
    "optimizer = optim.Adam(model.parameters(),\n",
    "                       lr=_lr, weight_decay=_weight_decay)\n",
    "\n",
    "#if args.cuda:\n",
    "#    model.cuda()\n",
    "#    features = features.cuda()\n",
    "#    adj = adj.cuda()\n",
    "#   labels = labels.cuda()\n",
    "#    idx_train = idx_train.cuda()\n",
    "#    idx_val = idx_val.cuda()\n",
    "#    idx_test = idx_test.cuda()\n",
    "\n",
    "\n",
    "def train(epoch):\n",
    "    t = time.time()\n",
    "    model.train()\n",
    "    optimizer.zero_grad()\n",
    "    output = model(features, adj,g_dict)\n",
    "    print(labels[idx_train])\n",
    "    loss_train = F.nll_loss(output[idx_train], labels[idx_train])\n",
    "    acc_train = accuracy(output[idx_train], labels[idx_train])\n",
    "    loss_train.backward()\n",
    "    optimizer.step()\n",
    "\n",
    "#    if not args.fastmode:\n",
    "        # Evaluate validation set performance separately,\n",
    "        # deactivates dropout during validation run.\n",
    "#        model.eval()\n",
    "#        output = model(features, adj)\n",
    "\n",
    "    loss_val = F.nll_loss(output[idx_val], labels[idx_val])\n",
    "    acc_val = accuracy(output[idx_val], labels[idx_val])\n",
    "    print('Epoch: {:04d}'.format(epoch+1),\n",
    "          'loss_train: {:.4f}'.format(loss_train.item()),\n",
    "          'acc_train: {:.4f}'.format(acc_train.item()),\n",
    "          'loss_val: {:.4f}'.format(loss_val.item()),\n",
    "          'acc_val: {:.4f}'.format(acc_val.item()),\n",
    "          'time: {:.4f}s'.format(time.time() - t))\n",
    "\n",
    "\n",
    "def test():\n",
    "    model.eval()\n",
    "    output = model(features, adj,g_dict)\n",
    "    loss_test = F.nll_loss(output[idx_test], labels[idx_test])\n",
    "    acc_test = accuracy(output[idx_test], labels[idx_test])\n",
    "    print(\"Test set results:\",\n",
    "          \"loss= {:.4f}\".format(loss_test.item()),\n",
    "          \"accuracy= {:.4f}\".format(acc_test.item()))\n",
    "\n",
    "\n",
    "# Train model\n",
    "t_total = time.time()\n",
    "for epoch in range(n_epochs):\n",
    "    train(epoch)\n",
    "print(\"Optimization Finished!\")\n",
    "print(\"Total time elapsed: {:.4f}s\".format(time.time() - t_total))\n",
    "\n",
    "# Testing\n",
    "test()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.6.5"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
